package Test;

public abstract class Animal {
    public void eat() {  

        System.out.println("Animal eats");
    }
    public int func(){
        return 111;
    }
    public void func2(){
        System.out.println(222);
    }
}
class Cat extends Animal{
    @Override
    public void eat() {
        System.out.println("Cat eats");
        System.out.println(func());
        func2();
    }
}
class Main2{
    public static void main(String[] args) {
        Animal animal = new Cat();
        animal.eat();
    }
}